<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>
    /*javascript变量的类型取决于它里面存放的值*/
    var num = 1;
    var str = "hello";
    var b1 = true;
    /*变量声明了，但是没有赋值的时候*/
    var u1 = undefined;
    /*null表示是一个空对象*/
    var n1 = null;

    /*使用typeof来进行变量类型的判断*/
    var num = "world"
    console.log(typeof num);
    console.log(typeof str);
</script>
</html>